<?php
namespace app\modules\developer\models;

use Yii;

class AppYearLimit extends \yii\db\ActiveRecord
{    
    public static function tableName()
    {
        return '{{%app_year_limit}}';
    }

    public function rules()
    {
        return [
            ['year', 'default', 'value' => 0],
            ['year', 'integer', 'message' => 'year必须为数字，或数字字符串', 
                     'min'=>-1, 'tooSmall' => 'year最小存储-1', 
                     'max'=>10, 'tooBig' => 'year最大存储10'],
            ['sort', 'integer', 'message' => 'sort必须为数字，或数字字符串', 
                     'min'=>0, 'tooSmall' => 'sort最小存储0', 
                     'max'=>10, 'tooBig' => 'sort最大存储10'],
        ];
    }

    
}